<template>
    <div style="width: 100%; page-break-before: always; "  v-if="data">
        <div style="font-weight: 32px;  font-weight: bold; border-bottom: 1px solid #333; padding: 12px;">
            我是 富文本
        </div>
        <div class="html-ctn" v-html="data.htmlStr" style="word-break: break-all; width: 100%;">

        </div>
    </div>
</template>
<style lang="less" scoped>
/depp/ .html-ctn {
    div, span, pre {
    word-break: break-all !important;
    width: 100%;
}
p {
    word-break: break-all;
    width: 100%;
}
}

</style>

<script setup>
const { data }  = await useFetch('/api/html')
/* console.log(data.value) */
</script>